<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%--
  Created by IntelliJ IDEA.
  User: kong
  Date: 16/2/18
  Time: 上午11:52
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<html>
<head>
    <title></title>
</head>

<body>
  <h1>ajaxTest</h1>
</body>
<c:url value="/js/vendor/jquery.min.js" var="jquery" />
<script type="text/javascript" src="${jquery}"></script>
<script type="text/javascript">
  $.ajaxSetup({
    async:false
  });
  $(function () {

    var mydata = {'id':'01EDFBDD749D757562F49DF28932E865','title':'文涛咬人','content':'我家文涛咬人','province':'广东','city':'东莞'};
    $.ajax({
      type :'PUT',
      url : '/note/01EDFBDD749D757562F49DF28932E865/',
      data : mydata,
      success:function(result){
        document.write(JSON.stringify(result));
      },
      error : function() {
        // view("异常！");
        alert("异常！");
      }
    });
  })
</script>
</html>
